home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 7 / BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso / Files / Hyper / U-Z / Videotape Catalog 2.cpt / VCR v2.0 / background_15914.txt < prev    next >
Text File  |  1990-04-09  |  3KB  |  131 lines

  1. -- background: 15914 from stack: in.0
  2. -- bmap block id: 15788
  3. -- flags: 0000
  4. -- background id: 0
  5. -- name: Init
  6. ----- HyperTalk script -----
  7. on poly
  8.   put 0 into sx
  9.   put 0 into sy
  10.   put 0 into sx2
  11.   put 0 into sx3
  12.   put 0 into sx4
  13.   put 0 into sxy
  14.   put 0 into sx2y
  15.   put number of lines in field 1 into n
  16.   repeat with i=1 to n
  17.     put (line i of field 1)/1000 into x
  18.     put line i of field 2 into y
  19.     add x to sx
  20.     add y to sy
  21.     add x*x to sx2
  22.     add x*x*x to sx3
  23.     add x*x*x*x to sx4
  24.     add x*y to sxy
  25.     add x*x*y to sx2y
  26.   end repeat
  27.   set numberFormat to "0.0000000"
  28.   put n*sx2*sx4+(sx*sx3*sx2)*2-sx2*sx2*sx2-sx3*sx3*n-sx*sx*sx4 into det
  29.   put (sy*sx2*sx4+sx*sx3*sx2y+sxy*sx3*sx2-sx2y*sx2*sx2-sx3*sx3*sy- sxy*sx*sx4)/det into line 1 of field 3
  30.   put (n*sxy*sx4+sy*sx3*sx2+sx*sx2y*sx2-sxy*sx2*sx2-sx2y*sx3*n- sy*sx*sx4)/det into line 2 of field 3
  31.   put (n*sx2*sx2y+sx*sx2*sxy+sy*sx3*sx-sy*sx2*sx2-sx3*sxy*n- sx2y*sx*sx)/det into line 3 of field 3
  32. end poly
  33.  
  34.  
  35. -- part 1 (field)
  36. -- low flags: 00
  37. -- high flags: 4000
  38. -- rect: left=24 top=54 right=305 bottom=67
  39. -- title width / last selected line: 0
  40. -- icon id / first selected line: 0 / 0
  41. -- text alignment: 0
  42. -- font id: 15026
  43. -- text size: 12
  44. -- style flags: 0
  45. -- line height: 16
  46. -- part name: 
  47.  
  48.  
  49. -- part 3 (field)
  50. -- low flags: 00
  51. -- high flags: 4000
  52. -- rect: left=86 top=54 right=305 bottom=126
  53. -- title width / last selected line: 0
  54. -- icon id / first selected line: 0 / 0
  55. -- text alignment: 0
  56. -- font id: 15026
  57. -- text size: 12
  58. -- style flags: 0
  59. -- line height: 16
  60. -- part name: 
  61.  
  62.  
  63. -- part 5 (field)
  64. -- low flags: 00
  65. -- high flags: 4000
  66. -- rect: left=321 top=225 right=277 bottom=434
  67. -- title width / last selected line: 0
  68. -- icon id / first selected line: 0 / 0
  69. -- text alignment: 0
  70. -- font id: 15026
  71. -- text size: 12
  72. -- style flags: 0
  73. -- line height: 16
  74. -- part name: 
  75.  
  76.  
  77. -- part 6 (button)
  78. -- low flags: 00
  79. -- high flags: 0000
  80. -- rect: left=410 top=96 right=138 bottom=457
  81. -- title width / last selected line: 0
  82. -- icon id / first selected line: 14767 / 14767
  83. -- text alignment: 1
  84. -- font id: 0
  85. -- text size: 12
  86. -- style flags: 0
  87. -- line height: 16
  88. -- part name: 
  89. ----- HyperTalk script -----
  90. on mouseUp
  91.   show field "Help"
  92. end mouseUp
  93.  
  94.  
  95.  
  96. -- part 7 (field)
  97. -- low flags: 01
  98. -- high flags: 0001
  99. -- rect: left=153 top=92 right=300 bottom=490
  100. -- title width / last selected line: 0
  101. -- icon id / first selected line: 0 / 0
  102. -- text alignment: 0
  103. -- font id: 15026
  104. -- text size: 12
  105. -- style flags: 0
  106. -- line height: 16
  107. -- part name: Help
  108. ----- HyperTalk script -----
  109. on mouseUp
  110.   hide field Help
  111. end mouseUp
  112.  
  113.  
  114. -- part 8 (button)
  115. -- low flags: 00
  116. -- high flags: 8003
  117. -- rect: left=31 top=298 right=320 bottom=131
  118. -- title width / last selected line: 0
  119. -- icon id / first selected line: 0 / 0
  120. -- text alignment: 1
  121. -- font id: 0
  122. -- text size: 12
  123. -- style flags: 0
  124. -- line height: 16
  125. -- part name: Initialize
  126. ----- HyperTalk script -----
  127. on mouseUp
  128.   poly
  129. end mouseUp
  130.  
  131.